package com.ibr.ticketmanagement.app.data;

import android.content.ContentValues;

import com.ibr.ticketmanagement.app.util.DatabaseHandler;

/**
 * Created by Girishn on 5/28/2014.
 */
public class LocationPart {
    private int _id;
    private long locationId;
    private long partId;
    private int quantity;

    public LocationPart(long locId, long part_id, int quantity) {
        this.locationId = locId;
        this.partId = part_id;
    }

    public int getQuantity() {
        return quantity;
    }

    public void setQuantity(int quantity) {
        this.quantity = quantity;
    }

    public long getPartId() {
        return partId;
    }

    public void setPartId(long partId) {
        this.partId = partId;
    }

    public long getLocationId() {
        return locationId;
    }

    public void setLocationId(long locationId) {
        this.locationId = locationId;
    }

    public int get_id() {
        return _id;
    }

    public void set_id(int _id) {
        this._id = _id;
    }

    public ContentValues getContentValues() {
        ContentValues values = new ContentValues();
        values.put(DatabaseHandler.KEY_LOCATION_PART_LOC_ID, getLocationId());
        values.put(DatabaseHandler.KEY_LOCATION_PART_PART_ID, getPartId());
        values.put(DatabaseHandler.KEY_LOCATION_PART_QUANTITY, getQuantity());
        return values;
    }
}
